
// <copyright file="Pair.cs" company="Subhadra Software Solutions">
//   
// </copyright>
// <summary>
//   The pair.
// </summary>

namespace SubhadraSolutions.Sharp.Utils.Collections.Generic
{
    /// <summary>
    /// The pair.
    /// </summary>
    /// <typeparam name="T1">
    /// The type of the 1.
    /// </typeparam>
    /// <typeparam name="T2">
    /// The type of the 2.
    /// </typeparam>
    public class Pair<T1, T2>
    {
        #region Constructors and Finalizers

        /// <summary>
        /// Initializes a new instance of the <see cref="Pair{T1,T2}"/> class.
        /// </summary>
        public Pair()
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="Pair{T1,T2}"/> class.
        /// </summary>
        /// <param name="first">
        /// The first.
        /// </param>
        /// <param name="second">
        /// The second.
        /// </param>
        public Pair(T1 first, T2 second)
        {
            this.First = first;
            this.Second = second;
        }

        #endregion Constructors and Finalizers

        #region Public Properties

        /// <summary>
        /// Gets or sets the first.
        /// </summary>
        public T1 First { get; set; }

        /// <summary>
        /// Gets or sets the second.
        /// </summary>
        public T2 Second { get; set; }

        #endregion Public Properties

        #region Public Methods and Operators

        /// <summary>
        /// The create new.
        /// </summary>
        /// <param name="first">
        /// The first.
        /// </param>
        /// <param name="second">
        /// The second.
        /// </param>
        /// <returns>
        /// The <see cref="Pair"/>.
        /// </returns>
        public static Pair<T1, T2> CreateNew(T1 first, T2 second)
        {
            return new Pair<T1, T2>(first, second);
        }

        #endregion Public Methods and Operators
    }
}